﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml;

namespace Cielo.API.XML.Helpers
{
    internal static class XMLElementExtensions
    {
        public static XmlElement GetUniqueElementByTagName(this XmlElement element, string name)
        {
            return (element.GetElementsByTagName(name)[0] as XmlElement);
        }
        public static XmlElement GetUniqueElementByTagName(this XmlDocument element, string name)
        {
            return (element.GetElementsByTagName(name)[0] as XmlElement);
        }

    }
}
